home *** CD-ROM | disk | FTP | other *** search
/ Amiga Magazin: Amiga-CD 1996 May & June / Amiga-CD 1996 #5-6.iso / demos / finaldata / fdmacros / autonameaddr next >
Text File  |  1996-03-22  |  2KB  |  54 lines

  1. /* ==================================================== */
  2. /* Final Data Arexx Macro - Make Name/Address File      */
  3. /* This macro creates a new 'standard' name and address */
  4. /* file which is used by several other macros named:    */
  5. /* STANDARDLABELS...*/
  6. /* */
  7. /* */
  8. /* */
  9. /* */
  10. /* by Dick Skraly - SoftWood, Inc.                      */
  11. /* $VER: FDNameAddr 1.2 (22.7.94)                       */
  12. /* ==================================================== */
  13.  
  14. /* ----- Initialization -----*/
  15.    Options Results
  16.    IF ( ADDLIB("rexxsupport.library", 0, -30, 0) = FALSE) THEN EXIT 20
  17.    HOST=ADDRESS()
  18.    ADDRESS VALUE HOST
  19.    HOSTleft=LEFT(HOST,7)
  20.    if HOSTleft ~== 'FINALD.' then EXIT 20
  21.  
  22. /* ----- Make sure this is what user wants to do ----- */
  23. /* ShowMessage 2 0 '"Create a new standard" "Name/Address database?" "" "Continue?" "Cancel" ""'   */
  24. /* if Result = 2 then exit 0  */
  25.  
  26. /* ----- Create and address the new window ----- */
  27.    i=1
  28.    do while SHOWLIST('P',HOSTleft||i)
  29.       i=i+1
  30.    end
  31.    NEWHOST = HOSTleft||i
  32.    New
  33.  
  34.    ADDRESS command
  35.    WaitForPort NEWHOST
  36.    ADDRESS VALUE NEWHOST
  37.  
  38. /* ----- Make new fixed Columns ----- */
  39.    InitNewColumn TEXT "Zip Code"
  40.    AddNewColumn
  41.    InitNewColumn TEXT "State"
  42.    AddNewColumn
  43.    InitNewColumn TEXT "City"
  44.    AddNewColumn
  45.    InitNewColumn TEXT "Address"
  46.    AddNewColumn
  47.    InitNewColumn TEXT "Last Name"
  48.    AddNewColumn
  49.    InitNewColumn TEXT "First Name"
  50.    AddNewColumn
  51.  
  52.    NewRow
  53.  
  54. exit RC /****** end of FDNameAddr.rexx ********************/